package com.itic.appbase.framework.utils;

import javax.servlet.http.HttpServletRequest;


public class IpAddressHelper {
	/**
     * 获取用户id测试方法
     * @param request
     * @return
     */
    public static String getRemortIP(HttpServletRequest request) {

        if (request.getHeader("x-forwarded-for") == null) {

            return request.getRemoteAddr();    

        }     

        return request.getHeader("x-forwarded-for");     

    }
}
